%s = [LBMA_data(1:30);s.'];

error = ACHAI-bit_pre;
X = zeros(1,30);
for i = 1:1796
    X(i,:)  = error(i:29+i);
end
Y  = error(31:1826);
MdlLin = fitrsvm(X,Y,'Standardize',true,'KFold',5)
MdlGau = fitrsvm(X,Y,'Standardize',true,'KFold',5,'KernelFunction','gaussian')

mseLin = kfoldLoss(MdlLin)
mseGau = kfoldLoss(MdlGau)
rng default
Mdl = fitrsvm(X,Y,'OptimizeHyperparameters','auto',...
    'HyperparameterOptimizationOptions',struct('AcquisitionFunctionName',...
    'expected-improvement-plus'))
% 预测
hold on;
figure;

fit = predict(Mdl,X)
plot(Y,fit,'.')
